package org.dromara.bclt.domain.vo;

import org.dromara.bclt.domain.Course;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import org.dromara.common.translation.annotation.Translation;
import org.dromara.common.translation.constant.TransConstant;

import java.io.Serial;
import java.io.Serializable;
import java.util.Date;



/**
 * 手环--课程视图对象 bclt_course
 *
 * @author RRyuan
 * @date 2024-10-21
 */
@Data
@ExcelIgnoreUnannotated
@AutoMapper(target = Course.class)
public class CourseVo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 课程id
     */
    @ExcelProperty(value = "课程id")
    private Long id;

    /**
     * 课程名称
     */
    @ExcelProperty(value = "课程名称")
    private String name;

    @ExcelProperty(value = "课程封面")
    private String avator;

    /**
     * 课程类型
     */
    @ExcelProperty(value = "课程类型", converter = ExcelDictConvert.class)
    @ExcelDictFormat(dictType = "bclt_course_type")
    private String bcltCourseType;

    /**
     * 课程url
     */
    @ExcelProperty(value = "课程url")
    private String url;

    /**
     * 课程总时长
     */
    @ExcelProperty(value = "课程总时长")
    private Long totalTime;

    @ExcelProperty(value = "课程排序")
    private Long courseOrder;

    private Long playProgress;

    private Long courseStatus;

    /**
     * 课程备注
     */
    @ExcelProperty(value = "课程备注")
    private String remark;

    /**
     * 创建时间
     */
    @ExcelProperty(value = "创建时间")
    private Date createTime;

    /**
     * 创建人
     */
    @ExcelProperty(value = "创建人")
    private Long createBy;
    /**
     * 创建人姓名
     */
    @ExcelProperty(value = "创建人")
    @Translation(type = TransConstant.USER_ID_TO_NAME, mapper = "createBy")
    private String createByName;

    /**
     * 更新时间
     */
    @ExcelProperty(value = "更新时间")
    private Date updateTime;


}
